#include <stdint.h>
#include <fcntl.h>
#include <unistd.h>
#include <string.h>
#include "module.h"
#include <stdint.h>
#include <sys/types.h>
#include <sys/time.h>
#include <time.h>
#include <sys/select.h>
#include "keymgt.h"
#include <sys/err.h>

/* MODEM API */
extern sys_api_t * sysapi;
int modem_get_sq(void)
{
    return sysapi->modem_get_sq(); 
}
int modem_get_info(modem_info_em type, char *info)
{
    return sysapi->modem_get_info(type, info);
}
int modem_get_station_info(modem_station_info_t *info)
{
    return sysapi->modem_get_station_info(info);
}
/*TCP API*/
int tcp_open(tcp_dev_em type)
{
    return sysapi->tcp_open(type);
}
int tcp_close(int fd)
{
    return sysapi->tcp_close(fd);
}
int tcp_connect(int fd, const char *ip, int port, int timeout)
{
    return sysapi->tcp_connect(fd, ip, port, timeout);
}
int tcp_write(int fd, const char* data, int data_len, int timeout)
{
    return sysapi->tcp_write(fd, data, data_len, timeout);
}
int tcp_read(int fd, char* buf, int req_len, int timeout)
{
    return sysapi->tcp_read(fd, buf, req_len, timeout);
}




